package com.example.demo.dao;

import com.example.demo.entity.TeacherBean;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface TeacherDao {
    
    List<TeacherBean> getAll();
    
    Integer insert(TeacherBean teacherBean);
    
    Integer edit(TeacherBean teacherBean);
    
    Integer del(Integer id);
    
    TeacherBean getOne(Integer id);
    
    TeacherBean getByUsername(String username);
    
    List<TeacherBean> getPage(
            @Param("jump") Integer jump,
            @Param("pageSize") Integer pageSize,
            @Param("name") String name,
            @Param("zhicheng") String zhicheng,
            @Param("sortOrder") String sortOrder
    );
    
    Integer getCount(
            @Param("name") String name,
            @Param("zhicheng") String zhicheng
    );
}
